package com.tomehay.termprojectmanage_server.controller;


import com.tomehay.termprojectmanage_server.pojo.Model.TaskGrades;
import com.tomehay.termprojectmanage_server.pojo.VO.GradeVO;
import com.tomehay.termprojectmanage_server.pojo.VO.ResultVO;
import com.tomehay.termprojectmanage_server.service.EvaluationsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author tomehay
 * @since 2023-06-20
 */
@RestController
@RequestMapping("api/evaluations")
public class EvaluationsController {

    @Autowired
    EvaluationsService evaluationsService;

    @GetMapping("/query")
    public ResultVO<List<GradeVO>> querygrades(@RequestParam(value = "groupnumber") int id){
        return evaluationsService.querygrades(id);

    }
}
